package com.itasura.scheduler;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @author sailor wang
 * @date 2018/11/11 10:11 PM
 * @description
 */
@Slf4j
@Component
public class Task2 {

    @Scheduled(cron = "*/2 * * * * ?")
    private void process() {
        log.info("两秒执行一次");
    }

}